<!DOCTYPE html>
<meta charset="utf-8">
<title>Make sure stroke-width is zoom agnostic when animating</title>
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>

<div id="target"></div>

<script>
test(t => {
  // Setting the zoom factor should not change the value of strokeWidth.
  if (window.testRunner)
    testRunner.setPageZoomFactor(5);

  const anim = target.animate([
    { strokeWidth: '10px' },
    { strokeWidth: '15px' },
  ], {
    duration: 1000,
  });

  anim.currentTime = 500;
  assert_equals(getComputedStyle(target).strokeWidth, '12.5px');
});
</script>
